<!--<html>-->
<% var img = 'img/avatar/%3Ddefault%3D/', imgType = 'jpeg'; %>
<% if (user.imgType) { img = 'img/avatar/'+user.name+'/'; imgType = user.imgType; } %>
<fieldset>
  <div><legend>修改头像</legend></div>
  <div class="avatar_setting">
    <div class="left">
      <img src="<%= img %>1.<%= imgType %>"/>
    </div>
    <div class="right fixed">
      <div class="avatar_b">
        <div class="img"><img src="<%= img %>2.<%= imgType %>"/></div>150X150像素
      </div>
      <div class="avatar_m">
        <div class="img"><img src="<%= img %>3.<%= imgType %>"/></div>75X75像素
      </div>
      <div class="avatar_s">
        <div class="img"><img src="<%= img %>4.<%= imgType %>"/></div>50X50像素
      </div>
    </div>
  </div>
  <div style="margin-left:350px;">
    <span class="uibtn upload-btn">
      <span>选择文件</span>
      <input type="file" id="file" name="img" data-url="/avatarUpload" />
    </span>
    <span id="upload-info" class="upload-info">未选择文件 (支持jpeg, jpg, png格式)</span>
  </div>
  <div class="form-horizontal">
    <div class="form-actions">
      <button class="uibtn" id="upload">确认上传</button>
      <span id="imgerr" class="error-text"></span>
      <img class="hide" id="imgload" style="height:22px;width=22px;"  src="/img/loading.gif">
    </div>
  </div>
</fieldset>